//
//  FlowerCollectionCell.m
//  BigToBig
//
//  Created by liuyi on 7/20/16.
//  Copyright © 2016 cn.cloudtp. All rights reserved.
//

#import "FlowerCollectionCell.h"

@implementation FlowerCollectionCell

- (instancetype)initWithFrame:(CGRect)frame{
    self = [super initWithFrame: frame];
    if (self) {
        [self createSubViews];
    }
    return self;
}

- (void)createSubViews{
    self.headImageView = [[UIImageView alloc]initWithFrame:CGRectMake(0, 0, self.width, self.width)];
    self.headImageView.layer.cornerRadius = self.width / 2;
    self.headImageView.layer.masksToBounds = YES;
    [self.contentView addSubview:self.headImageView];
    self.nameLabel = [[UILabel alloc]initWithFrame:CGRectMake(0, self.width + 5, self.width, 95 - self.width)];
    self.nameLabel.textAlignment = 1;
    [self.contentView addSubview:self.nameLabel];
}

- (void)layoutSubviews{
    self.headImageView.frame = CGRectMake(0, 0, self.width, self.width);
    self.nameLabel.frame = CGRectMake(0, self.width + 5, self.width, 95 - self.width);
}

@end
